package training.bms.presentation;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;

import training.bms.business.Post;
import training.bms.business.PostController;
import training.bms.business.PostSearchOptions;
import training.framework.business.AbstractEntityController;
import training.framework.presentation.AbstractNewEntity;

@ManagedBean
@SessionScoped
public class NewPost extends AbstractNewEntity<Integer, Post, PostSearchOptions, PostPanel>{

	private PostController controller;
	public NewPost() {
		super(
				Post.class, 
				PostPanel.class, 
				"newPost", 
				"Post has been successfully saved!");
		controller = new PostController();
	}

	@Override
	protected AbstractEntityController<Integer, Post, PostSearchOptions> getController() {
	
		return controller;
	}
}